<?php
/* @var $this EventGiftPasswordController */
/* @var $model EventGiftPassword */

$this->breadcrumbs=array(
	'Event Gift Record'=>array('admin'),
	'Manage',
);
Yii::app()->clientScript->registerScript('search', "
$('#search-form form').submit(function(){
	$('#event-gift-password-grid').yiiGridView('update', {
		data: $(this).serialize()
	});
	return false;
});
");
?>
<div class="row-fluid">
	<div class="span12">
    	<div class="box gradient">
        	<div class="title">
           	<?php echo CHtml::link(Yii::t('common','Advanced Search'),'#collapseOne',array('class'=>'search-button accordion-toggle collapsed btn btn-mini zyBtn03','data-toggle'=>'collapse','data-parent'=>'#accordion2')); ?>
                <h3> <i class="icon-sitemap"></i> <span><?php echo Yii::t('Event Gift Password','Manage Event Gift Record') ?></span> </h3>
            </div>
            
			<div class="content"> 
			
 			<!--search start-->
 			
              <?php $this->renderPartial('_search1',array(
					'model'=>$model,
				)); ?>
              
            <!--search over-->
            
            <!-- table start -->
            
<?php $this->widget('application.extensions.zgrid.ZGridView', array(
	'id'=>'event-gift-password-grid',
	'dataProvider'=>$model->search2(),
	'itemsCssClass'=>'responsive table table-striped table-bordered',
	'pager'=>array('class'=>'CLinkPager','hiddenPageCssClass'=>'','firstPageCssClass'=>'first paginate_button','firstPageLabel'=>'First','prevPageLabel' => 'Previous','nextPageLabel' => 'Next','lastPageLabel'=>'Last','htmlOptions'=>array('class'=>'dataTables_paginate paging_full_numbers"'),'header'=>""),
	'pagerCssClass'=>'pagination',
	'cssFile'=>false,
	'template'=>'{items}{summary}{pager}',
	'summaryText'=>'Default Pagination',	
	'columns'=>array(
		array('name'=>'service_number','headerHtmlOptions'=>array('style'=>'width:10%')),
		array('name'=>'event_id','headerHtmlOptions'=>array('style'=>'width:10%'),'value'=>'EventGiftPassword::model()->getEventNames($data->event_id)'),
		array('name'=>'password','headerHtmlOptions'=>array('style'=>'width:10%')),
		array('name'=>'state','headerHtmlOptions'=>array('style'=>'width:10%'),'value'=>'EventGiftPassword::model()->getState($data->state)'),
		array('name'=>'time','headerHtmlOptions'=>array('style'=>'width:10%')),		
		array('name'=>'moblie','headerHtmlOptions'=>array('style'=>'width:10%')),
		array('name'=>'address','headerHtmlOptions'=>array('style'=>'width:10%'),'value'=>'EventGiftPassword::model()->getAddress($data->address)'),
	),
)); ?>
					<!--table over -->
			</div><!--//content-->
		</div><!--//box-->
	</div><!--//span12-->
</div><!--//row-fluid-->
